/** 
 * @(#)RIPRoutingEntry.java
 */

/**
 * @author Didier Gutacker
 * @version 1.0
 * @see RoutingEntry
 * @see RIPRoutingTable 
 *
 */

import java.util.Vector;

public class RIPRoutingEntry extends RoutingEntry {

  // additional attributes
  
  public RIPRoutingTable table;

  public boolean pruned = false;
  public int pruningTimer = 0;

  public RIPRoutingEntry( RIPRoutingTable table, int destinationID, int metric, LinkRIP l, int infinity ) {
    super( destinationID, metric, l, infinity );
    children = new Vector();
    this.table = table;
    DEBUG = new debug();
  } // RIPRoutingEntry.RIPRoutingEntry
 
  public final boolean update( int destinationID, int metric, LinkRIP l, int infinity ) {
    LinkRIP oldLink = ( LinkRIP )table.lookUp( destinationID ).l;
    boolean newRouteAccepted = super.update( destinationID, metric, l, infinity );
    return newRouteAccepted;
  } // RIPRoutingEntry.update

} // RIPRoutingEntry
